<template>
	<canvas ref="scale"></canvas>
</template>

<script>
export default {

	data() {
		return {
			canvasContext:{}
		}
	},
	mounted() {
		this.$nextTick(() => {
			this.initCanvas();
		})
	},
	methods: {
		initCanvas() {
			//刻度尺数量
			const itemNum = 10;
			const canvas = this.$refs.scale;
			canvas.width = canvas.parentNode.clientWidth;

		},
	}
}
</script>

<style lang="less">
.mb-ruler {
	overflow: hidden;
}
</style>
